﻿namespace BambuBusParser;
using System.Runtime.InteropServices;


// 定义 Filament 结构
[StructLayout(LayoutKind.Sequential, Pack = 4)]
public struct Filament
{
    [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 8)]
    public string ID; // 字符串长度 8

    public byte ColorR;
    public byte ColorG;
    public byte ColorB;
    public byte ColorA;

    public short TemperatureMin;
    public short TemperatureMax;

    [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 20)]
    public string Name; // 字符串长度 20

    public float Meters;
    public FilamentStatus Status;
    public FilamentMotionState MotionSet;
    public ushort Pressure;
}

// 定义 FlashSaveStruct 结构

// 全局常量